<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    div:not(#app){
      padding: 50px;
    }
    #div1{
      background-color: rgb(143, 34, 34);
    }
    #div2{
      background-color: rgb(197, 194, 38);
    }
    #div3{
      background-color: rgb(29, 219, 203);
    }
  </style>
</head>
<body>
  
  <div id="app">
    <div id="div1" @click="fn3()">
      <div id="div2" @click.capture="fn2()">
        <div id="div3" @click="fn1()"></div>
      </div>
    </div>
    <a href="http://www.baidu.com" @click.prevent="link">link</a>
  </div>
  <script src="./vue.js"></script>
  <script>
    const vm = new Vue({
      el: '#app',
      data: {},
      methods: {
        fn1(){
          alert(1)
        },
        fn2(){
          alert(2)
        },
        fn3(){
          alert(3)
        },
        link(){
          console.log(111);
          
        }
      }
    })

  </script>
</body>
</html>